import request from "@/router/axios";

export const getTeam = params => {
  return request({
    url: "/api/blade-measure/measure/report/team",
    method: "get",
    params: {
      ...params
    }
  });
};
export const saveReport = params => {
  return request({
    url: "/api/blade-measure/measure/report/team",
    method: "post",
    data: {
      ...params
    }
  });
};

export const getTeamWarn = params => {
  return request({
    url: "/api/blade-measure/measure/report/team/warn",
    method: "get",
    params: {
      ...params
    }
  });
};

export const getSampleTotal = params => {
  return request({
    url: "/api/blade-measure/measure/report/team/count",
    method: "get",
    params: {
      ...params
    }
  });
};

export const getViewByProjectId = params => {
  return request({
    url: "/api/blade-measure/measure/projectgaugesubject/viewByProjectId",
    method: "get",
    params: {
      ...params
    }
  });
};
export const getProjectInfo = (current, size, params) => {
  return request({
    url: "/api/blade-measure/measure/projectgaugesubject/listByProjectId",
    method: "get",
    params: {
      ...params,
      current,
      size
    }
  });
};
export const getCensusList = (current, size, params) => {
  return request({
    url: "/api/blade-measure/measure/project/list",
    method: "get",
    params: {
      ...params,
      current,
      size
    }
  });
};
export const getGaugeTypeTree = (current, size, params) => {
  return request({
    url: "/api/blade-measure/measure/projectgaugetype/list",
    method: "get",
    params: {
      ...params,
      current,
      size
    }
  });
};
export const releaseProject = params => {
  return request({
    url: "/api/blade-measure/measure/project/release",
    method: "post",
    data: {
      ...params
    }
  });
};

export const saveCensus = params => {
  return request({
    url: "/api/blade-measure/measure/project/save",
    method: "post",
    data: {
      ...params
    }
  });
};

export const updateCensus = params => {
  return request({
    url: "/api/blade-measure/measure/project/update",
    method: "post",
    data: {
      ...params
    }
  });
};

export const getDictListInfo = params => {
  return request({
    url: "/api/blade-system/dict/list?code=MHT&current=1&size=1000",
    method: "get",
    params: {
      ...params
    }
  });
};
